#include <stdio.h>
#include <time.h>
#include "config.h"
#include "mxml.h"

CONF conf;
int init(const char *conf_file)
{
	FILE *conf_fp = NULL;
	mxml_node_t *tree;
	conf_fp = fopen(conf_file, "r");
	if (!conf_fp)
		return -1;
	memset(&conf, 0, sizeof conf);
	tree = mxmlLoadFile(NULL, fp, MXML_TEXT_CALLBACK);

	mxml_node_t *node = mxmlFindElement(tree, tree, "url_dist", NULL, NULL, MXML_DESCEND);
	if (!node) {
		fclose(conf_fp);
		return -1;
	}
	for (mxml_node_t *i = node->child; ; i = i->next) {
	}
}
